'use strict';

const BASEDIR = __dirname
const TARGET = process.env.NODE_ENV || 'development'

module.exports = {

    BASEDIR,
    TARGET,

    //FOUNDATION_PREFIX: 'https://api.test.medatc.cc/fdn/v1',
    FOUNDATION_PREFIX: 'http://localhost:8100/v1',
    IBUPRO_CLOUD_PREFIX: 'https://api.test.medatc.cc/cloud/v1',
    //SERVICE_TOKEN: 'ba5099c1b1b14fa42016e2468ff297b38808fd9ca4e31e1930b6b2b27b415bb7',
    SERVICE_TOKEN: '0024c70d97624f69a71f6dd3d72e4b702e947a0957459d3e20526f3958c4f26d',

    MDISP_PREFIX: 'http://tools.medatc.cc/api',
    MDISP_TOKEN: '7bf49f2eb1be63dca150c776574887255663f6d659561ce5fdefc73cb51b5540',

    BASE_HREF: 'http://localhost:8100',

    redis: {
        cache: {
            host: '127.0.0.1',
            port: 6379,
            db: 0
        },
        storage: {
            host: '127.0.0.1',
            port: 6379,
            db: 1
        },
        pubsub: {
            host: '127.0.0.1',
            port: 6379,
            db: 2
        }
    },

    mysql: {
        sophic: {
            dialect: 'mysql',
            dialectOptions: {
                charset: 'utf8mb4'
            },
            replication: {
                read: [{
                    port: 3306,
                    host: 'localhost',
                    username: 'mdx',
                    password: '84cba24fe765e8a1e454e70bf31c8181',
                    database: 'mdx'
                }],
                write: {
                    port: 3306,
                    host: 'localhost',
                    username: 'mdx',
                    password: '84cba24fe765e8a1e454e70bf31c8181',
                    database: 'mdx'
                }
            },
            logging: false,
            timezone: '+08:00'
        }
    },
    aws: {
        region: 'cn-north-1',
        publicBucket: {
            Bucket: 's3.dev.medevicedata.com',
            ACL: 'public-read',
            ContentType: 'image/',
            Expires: 60 * 5
        },
        s3: {
            accessKeyId: 'AKIAOFO4GDDV66K7HDYQ',
            secretAccessKey: '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'
        },
        sqs: 'https://sqs.cn-north-1.amazonaws.com.cn/456323121134',
        env: 'dev',
    }
}